package ThreadDome;

public class Dome3 {
    public static void main(String[] args) {
        Thread t = new Thread() {
            public void run() {
                for (int i = 0; i < 5; i++) {
                    try {
                    Thread.sleep(1000);
                    } catch (InterruptedException e) {
                    throw new RuntimeException(e);
                }
                    System.out.println("线程启动");
                }
            }
        };
        t.start();
    }
}
